package util;

import java.util.Comparator;

public class MarketValueComparator implements Comparator<String> {

  @Override
  public int compare(String arg0, String arg1) {
    if(arg0.equals("unknown") || arg1.equals("unknown")){
      return -2;
    }
    Double firstNumber = Constants._dotNumberToDouble(arg0);
    Double secondNumber = Constants._dotNumberToDouble(arg1);
    return firstNumber.compareTo(secondNumber);
  }
}
